package com.sunwayworld.basemodule.common.eptstorage.equiptacqschedule.resource.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import com.sunwayworld.basemodule.common.eptstorage.equiptacqschedule.resource.LimsEquiptAcqScheduleTaskResource;
import com.sunwayworld.basemodule.common.eptstorage.equiptacqschedule.service.LimsEquiptAcqScheduleTaskService;
import com.sunwayworld.framework.spring.annotation.GikamBean;
import com.sunwayworld.framework.log.annotation.Log;
import com.sunwayworld.framework.log.annotation.LogModule;
import com.sunwayworld.framework.log.annotation.LogType;
import com.sunwayworld.framework.restful.data.RestJsonWrapperBean;

@LogModule("设备采集定时任务")
@RestController
@GikamBean
public class LimsEquiptAcqScheduleTaskResourceImpl implements LimsEquiptAcqScheduleTaskResource {

    @Autowired
    private LimsEquiptAcqScheduleTaskService limsEquiptAcqScheduleTaskService;

    @Override
    public LimsEquiptAcqScheduleTaskService getService() {
        return limsEquiptAcqScheduleTaskService;
    }

    @Log(value = "新增设备采集定时任务", type = LogType.INSERT)
    @Override
    @RequestMapping(method = RequestMethod.POST)
    public Long insert(RestJsonWrapperBean wrapper) {
        return getService().insert(wrapper);
    }

    @Override
    @RequestMapping(value = "/sendMsgToEquipt/30s", method = RequestMethod.POST)
    public void sendMsgToEquipt_30s() {
        getService().sendMsgToEquipt_30s();
    }
}
